const state = {
    labs: [],
    labIds: [],
    selectTag: ''
}

const mutations = {
    addLabs: (state,lab) => {
       state.labs.push(lab)
    },
    delLabs: (state,index) => {
        state.labs.splice(index,1)
    },
    addLabIds: (state,id) =>{
        state.labIds.push(id)
    },
    delLabIds: (state,index) =>{
        state.labIds.splice(index,1)
    },
    setSelectTag: (state,selectTag) => {
        state.selectTag = selectTag
    }
}
const actions = {

}
const getters = {
    getLabs : (state)=>{
      return state.labs
    },
    getLabIds: (state)=>{
        return state.labIds
    },
    getSelectTag: (state)=>{
        return state.selectTag
    }
}

export default {
    namespaced : true,
    state,
    mutations,
    actions,
    getters
}